using System;
using System.Data.Entity.ModelConfiguration;
using System.Data.Common;
using System.Data.Entity;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using DomainLayer.Data.Entities;

namespace Infrastructure.Data.Mapping
{
	public class FMS_FeeApplyMap : EntityTypeConfiguration<FMS_FeeApply>
	{
		public FMS_FeeApplyMap()
		{
			// Primary Key
			this.HasKey(t => t.ID);

			// Properties
			this.Property(t => t.Name)
				.HasMaxLength(100);
				
			this.Property(t => t.RefuseReason)
				.HasMaxLength(200);
				
			this.Property(t => t.InvalidReason)
				.HasMaxLength(200);
				
			this.Property(t => t.SaveFeeEmp)
				.HasMaxLength(100);
				
			this.Property(t => t.SaveFeeEmpAccount)
				.HasMaxLength(100);
				
			this.Property(t => t.PaymentAccount)
				.HasMaxLength(20);
				
			this.Property(t => t.PaymentType)
				.HasMaxLength(20);
				
			this.Property(t => t.Description)
				.HasMaxLength(200);
				
			this.Property(t => t.ApplyDesc)
				.HasMaxLength(200);
				
			// Table & Column Mappings
			this.ToTable("FMS_FeeApply");
			this.Property(t => t.ID).HasColumnName("ID");
			this.Property(t => t.DoUserID).HasColumnName("DoUserID");
			this.Property(t => t.BizOrderTypeID).HasColumnName("BizOrderTypeID");
			this.Property(t => t.Name).HasColumnName("Name");
			this.Property(t => t.Status).HasColumnName("Status");
			this.Property(t => t.CommitStatus).HasColumnName("CommitStatus");
			this.Property(t => t.ApproveStartDate).HasColumnName("ApproveStartDate");
			this.Property(t => t.ApproveStopDate).HasColumnName("ApproveStopDate");
			this.Property(t => t.CommitDate).HasColumnName("CommitDate");
			this.Property(t => t.RefuseDate).HasColumnName("RefuseDate");
			this.Property(t => t.RefuseReason).HasColumnName("RefuseReason");
			this.Property(t => t.InvalidReason).HasColumnName("InvalidReason");
			this.Property(t => t.SaveFeeEmp).HasColumnName("SaveFeeEmp");
			this.Property(t => t.SaveFeeEmpAccount).HasColumnName("SaveFeeEmpAccount");
			this.Property(t => t.AttachmentCount).HasColumnName("AttachmentCount");
			this.Property(t => t.ProcessDep).HasColumnName("ProcessDep");
			this.Property(t => t.FeeDep).HasColumnName("FeeDep");
			this.Property(t => t.PaymentAccount).HasColumnName("PaymentAccount");
			this.Property(t => t.PaymentType).HasColumnName("PaymentType");
			this.Property(t => t.Amount).HasColumnName("Amount");
			this.Property(t => t.MatchOrderID).HasColumnName("MatchOrderID");
			this.Property(t => t.CreateYear).HasColumnName("CreateYear");
			this.Property(t => t.CreateMonth).HasColumnName("CreateMonth");
			this.Property(t => t.CreateDay).HasColumnName("CreateDay");
			this.Property(t => t.EndYear).HasColumnName("EndYear");
			this.Property(t => t.EndMonth).HasColumnName("EndMonth");
			this.Property(t => t.EndDay).HasColumnName("EndDay");
			this.Property(t => t.Description).HasColumnName("Description");
			this.Property(t => t.CreateUser).HasColumnName("CreateUser");
			this.Property(t => t.UpdateUser).HasColumnName("UpdateUser");
			this.Property(t => t.CreateTime).HasColumnName("CreateTime");
			this.Property(t => t.UpdateTime).HasColumnName("UpdateTime");
			this.Property(t => t.IsDelete).HasColumnName("IsDelete");
			this.Property(t => t.CreateDeptId).HasColumnName("CreateDeptId");
			this.Property(t => t.UpdateDeptId).HasColumnName("UpdateDeptId");
			this.Property(t => t.OverDate).HasColumnName("OverDate");
			this.Property(t => t.RelationType).HasColumnName("RelationType");
			this.Property(t => t.AllFee).HasColumnName("AllFee");
			this.Property(t => t.ApplyDesc).HasColumnName("ApplyDesc");
		}
	}
}

